package com.fire.web.modules.all.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import org.apache.commons.lang3.builder.ReflectionToStringBuilder;

import java.io.Serializable;

/**
 * 收货区域
 *
 * @author Matthew
 * @Date 2019-01-17 20:18
 */
@TableName("t_receive_area")
public class ReceiveAreaModel extends Model<ReceiveAreaModel> {

    private static final long serialVersionUID = 1L;


    /**
     * 收货区域ID
     *
     */
    @TableField(value="areaid")
    @Excel(name = "收货区域ID")
    @TableId(value = "areaid", type= IdType.INPUT)
    private Integer areaid;
    /**
     * 区域名称(省
     * 区域名称(省,地市,区)
     */
    @TableField(value="areaname")
    @Excel(name = "区域名称(省")
    private String areaname;
    /**
     * 父节点
     *
     */
    @TableField(value="parentid")
    @Excel(name = "父节点")
    private Integer parentid;
    /**
     * 级别
     *
     */
    @TableField(value="level")
    @Excel(name = "级别")
    private String level;
    /**
     * 获取: 收货区域ID
     *
     */
    public Integer getAreaid() {
        return areaid;
    }
    /**
     * 设置: 收货区域ID
     *
     */
    public void setAreaid(Integer areaid) {
        this.areaid = areaid;
    }
    /**
     * 获取: 区域名称(省
     * 区域名称(省,地市,区)
     */
    public String getAreaname() {
        return areaname;
    }
    /**
     * 设置: 区域名称(省
     * 区域名称(省,地市,区)
     */
    public void setAreaname(String areaname) {
        this.areaname = areaname;
    }
    /**
     * 获取: 父节点
     *
     */
    public Integer getParentid() {
        return parentid;
    }
    /**
     * 设置: 父节点
     *
     */
    public void setParentid(Integer parentid) {
        this.parentid = parentid;
    }
    /**
     * 获取: 级别
     *
     */
    public String getLevel() {
        return level;
    }
    /**
     * 设置: 级别
     *
     */
    public void setLevel(String level) {
        this.level = level;
    }

    @Override
    protected Serializable pkVal() {
        return this.areaid;
    }

    @Override
    public String toString() {
        return ReflectionToStringBuilder.toString(this);
    }
}
